<template>
    <div class="radio">
        <div v-if='zjchacked==true' class=" kuang ">
            <div class="xuanzhong"></div>
        </div>
        <div v-if='zjchacked==false' class="kuang"></div>
    </div>
</template>

<script>
    export default {
        name:"Radio",
        data(){
            return{
                zjchacked:'',
            }
        },
        props: ["chacked"],
        created () {
            this.zjchacked = this._props.chacked; // 获取父组件的参数值
        },
        methods: {
            getchange() {
                this.zjchacked = this._props.chacked;
            }
        },
        watch:{
            chacked:function(){
                this.zjchacked = this._props.chacked;
            },
        }
    }
</script>

<style  scoped>

.kuang{
    width:26px;
    height:26px;
    border:4px solid #D1D1D1;
    border-radius: 50%;
    position: relative;
}
.xuanzhong{
    width:16px;
    height:16px;
    background:rgba(52,219,137,1);
    border-radius:50%;
    position: absolute;
    top:50%;
    left:50%;
    transform: translate(-50%,-50%);
}

</style>